3.213 \(\int \frac{a+b \log (c x^n)}{x (d+e x^2)} \, dx\)

Optimal. Leaf size=49 \[ \frac{b n \text{PolyLog}\left (2,-\frac{d}{e x^2}\right )}{4 d}-\frac{\log \left (\frac{d}{e x^2}+1\right ) \left (a+b \log \left (c x^n\right )\right )}{2 d} \]

[Out]

-(Log[1 + d/(e*x^2)]*(a + b*Log[c*x^n]))/(2*d) + (b*n*PolyLog[2, -(d/(e*x^2))])/(4*d)

________________________________________________________________________________________

Rubi [A]  time = 0.0645087, antiderivative size = 49, normalized size of antiderivative = 1., number of steps used = 2, number of rules used = 2, integrand size = 23, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.087, Rules used = {2345, 2391} \[ \frac{b n \text{PolyLog}\left (2,-\frac{d}{e x^2}\right )}{4 d}-\frac{\log \left (\frac{d}{e x^2}+1\right ) \left (a+b \log \left (c x^n\right )\right )}{2 d} \]

Antiderivative was successfully verified.

[In]

Int[(a + b*Log[c*x^n])/(x*(d + e*x^2)),x]

[Out]

-(Log[1 + d/(e*x^2)]*(a + b*Log[c*x^n]))/(2*d) + (b*n*PolyLog[2, -(d/(e*x^2))])/(4*d)

Rule 2345

Int[((a_.) + Log[(c_.)*(x_)^(n_.)]*(b_.))^(p_.)/((x_)*((d_) + (e_.)*(x_)^(r_.))), x_Symbol] :> -Simp[(Log[1 +
d/(e*x^r)]*(a + b*Log[c*x^n])^p)/(d*r), x] + Dist[(b*n*p)/(d*r), Int[(Log[1 + d/(e*x^r)]*(a + b*Log[c*x^n])^(p
 - 1))/x, x], x] /; FreeQ[{a, b, c, d, e, n, r}, x] && IGtQ[p, 0]

Rule 2391

Int[Log[(c_.)*((d_) + (e_.)*(x_)^(n_.))]/(x_), x_Symbol] :> -Simp[PolyLog[2, -(c*e*x^n)]/n, x] /; FreeQ[{c, d,
 e, n}, x] && EqQ[c*d, 1]

Rubi steps

\begin{align*} \int \frac{a+b \log \left (c x^n\right )}{x \left (d+e x^2\right )} \, dx &=-\frac{\log \left (1+\frac{d}{e x^2}\right ) \left (a+b \log \left (c x^n\right )\right )}{2 d}+\frac{(b n) \int \frac{\log \left (1+\frac{d}{e x^2}\right )}{x} \, dx}{2 d}\\ &=-\frac{\log \left (1+\frac{d}{e x^2}\right ) \left (a+b \log \left (c x^n\right )\right )}{2 d}+\frac{b n \text{Li}_2\left (-\frac{d}{e x^2}\right )}{4 d}\\ \end{align*}

Mathematica [B]  time = 0.0818811, size = 126, normalized size = 2.57 \[ -\frac{b^2 n^2 \text{PolyLog}\left (2,\frac{\sqrt{e} x}{\sqrt{-d}}\right )+b^2 n^2 \text{PolyLog}\left (2,\frac{d \sqrt{e} x}{(-d)^{3/2}}\right )-\left (a+b \log \left (c x^n\right )\right ) \left (a+b \log \left (c x^n\right )-b n \log \left (\frac{\sqrt{e} x}{\sqrt{-d}}+1\right )-b n \log \left (\frac{d \sqrt{e} x}{(-d)^{3/2}}+1\right )\right )}{2 b d n} \]

Antiderivative was successfully verified.

[In]

Integrate[(a + b*Log[c*x^n])/(x*(d + e*x^2)),x]

[Out]

-(-((a + b*Log[c*x^n])*(a + b*Log[c*x^n] - b*n*Log[1 + (Sqrt[e]*x)/Sqrt[-d]] - b*n*Log[1 + (d*Sqrt[e]*x)/(-d)^
(3/2)])) + b^2*n^2*PolyLog[2, (Sqrt[e]*x)/Sqrt[-d]] + b^2*n^2*PolyLog[2, (d*Sqrt[e]*x)/(-d)^(3/2)])/(2*b*d*n)

________________________________________________________________________________________

Maple [C]  time = 0.212, size = 439, normalized size = 9. \begin{align*} \text{result too large to display} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((a+b*ln(c*x^n))/x/(e*x^2+d),x)

[Out]

b*ln(x^n)/d*ln(x)-1/2*b*ln(x^n)/d*ln(e*x^2+d)-1/2*b*n/d*ln(x)^2-1/2*b*n/d*ln(x)*ln((-e*x+(-d*e)^(1/2))/(-d*e)^
(1/2))-1/2*b*n/d*ln(x)*ln((e*x+(-d*e)^(1/2))/(-d*e)^(1/2))+1/2*b*n/d*ln(x)*ln(e*x^2+d)-1/2*b*n/d*dilog((-e*x+(
-d*e)^(1/2))/(-d*e)^(1/2))-1/2*b*n/d*dilog((e*x+(-d*e)^(1/2))/(-d*e)^(1/2))-1/2*I*b*Pi*csgn(I*x^n)*csgn(I*c*x^
n)*csgn(I*c)/d*ln(x)+1/2*I*b*Pi*csgn(I*c*x^n)^2*csgn(I*c)/d*ln(x)+1/4*I*b*Pi*csgn(I*c*x^n)^3/d*ln(e*x^2+d)+1/4
*I*b*Pi*csgn(I*x^n)*csgn(I*c*x^n)*csgn(I*c)/d*ln(e*x^2+d)-1/4*I*b*Pi*csgn(I*c*x^n)^2*csgn(I*c)/d*ln(e*x^2+d)-1
/2*I*b*Pi*csgn(I*c*x^n)^3/d*ln(x)+1/2*I*b*Pi*csgn(I*x^n)*csgn(I*c*x^n)^2/d*ln(x)-1/4*I*b*Pi*csgn(I*x^n)*csgn(I
*c*x^n)^2/d*ln(e*x^2+d)+b*ln(c)/d*ln(x)-1/2*b*ln(c)/d*ln(e*x^2+d)+a/d*ln(x)-1/2*a/d*ln(e*x^2+d)

________________________________________________________________________________________

Maxima [F]  time = 0., size = 0, normalized size = 0. \begin{align*} -\frac{1}{2} \, a{\left (\frac{\log \left (e x^{2} + d\right )}{d} - \frac{2 \, \log \left (x\right )}{d}\right )} + b \int \frac{\log \left (c\right ) + \log \left (x^{n}\right )}{e x^{3} + d x}\,{d x} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+b*log(c*x^n))/x/(e*x^2+d),x, algorithm="maxima")

[Out]

-1/2*a*(log(e*x^2 + d)/d - 2*log(x)/d) + b*integrate((log(c) + log(x^n))/(e*x^3 + d*x), x)

________________________________________________________________________________________

Fricas [F]  time = 0., size = 0, normalized size = 0. \begin{align*}{\rm integral}\left (\frac{b \log \left (c x^{n}\right ) + a}{e x^{3} + d x}, x\right ) \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+b*log(c*x^n))/x/(e*x^2+d),x, algorithm="fricas")

[Out]

integral((b*log(c*x^n) + a)/(e*x^3 + d*x), x)

________________________________________________________________________________________

Sympy [A]  time = 19.8318, size = 124, normalized size = 2.53 \begin{align*} \frac{a \log{\left (x \right )}}{d} - \frac{a \log{\left (d + e x^{2} \right )}}{2 d} + \frac{b n \left (\begin{cases} \log{\left (e \right )} \log{\left (x \right )} + \frac{\operatorname{Li}_{2}\left (\frac{d e^{i \pi }}{e x^{2}}\right )}{2} & \text{for}\: \left |{x}\right | < 1 \\- \log{\left (e \right )} \log{\left (\frac{1}{x} \right )} + \frac{\operatorname{Li}_{2}\left (\frac{d e^{i \pi }}{e x^{2}}\right )}{2} & \text{for}\: \frac{1}{\left |{x}\right |} < 1 \\-{G_{2, 2}^{2, 0}\left (\begin{matrix} & 1, 1 \\0, 0 & \end{matrix} \middle |{x} \right )} \log{\left (e \right )} +{G_{2, 2}^{0, 2}\left (\begin{matrix} 1, 1 & \\ & 0, 0 \end{matrix} \middle |{x} \right )} \log{\left (e \right )} + \frac{\operatorname{Li}_{2}\left (\frac{d e^{i \pi }}{e x^{2}}\right )}{2} & \text{otherwise} \end{cases}\right )}{2 d} - \frac{b \log{\left (c x^{n} \right )} \log{\left (\frac{d}{x^{2}} + e \right )}}{2 d} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+b*ln(c*x**n))/x/(e*x**2+d),x)

[Out]

a*log(x)/d - a*log(d + e*x**2)/(2*d) + b*n*Piecewise((log(e)*log(x) + polylog(2, d*exp_polar(I*pi)/(e*x**2))/2
, Abs(x) < 1), (-log(e)*log(1/x) + polylog(2, d*exp_polar(I*pi)/(e*x**2))/2, 1/Abs(x) < 1), (-meijerg(((), (1,
 1)), ((0, 0), ()), x)*log(e) + meijerg(((1, 1), ()), ((), (0, 0)), x)*log(e) + polylog(2, d*exp_polar(I*pi)/(
e*x**2))/2, True))/(2*d) - b*log(c*x**n)*log(d/x**2 + e)/(2*d)

________________________________________________________________________________________

Giac [F]  time = 0., size = 0, normalized size = 0. \begin{align*} \int \frac{b \log \left (c x^{n}\right ) + a}{{\left (e x^{2} + d\right )} x}\,{d x} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+b*log(c*x^n))/x/(e*x^2+d),x, algorithm="giac")

[Out]

integrate((b*log(c*x^n) + a)/((e*x^2 + d)*x), x)